/*
 * Redirect.java
 * 
 * Version Information
 * Date Mar 20, 2006
 *
 * Copyright (c) AmSoft Systems, 2006
 */

package net.amsoft.iservice.ilink.hibernate;

import org.apache.log4j.Logger;

public class Redirect extends ILinkBaseClass {
	private static final Logger oLogger = Logger.getLogger(Redirect.class);

	private Synonym oSynonym;

	private String sWebResource;

	private String sTag;

	private boolean bPublic;

	public Redirect() {
	}

	/**
	 * @param synonym
	 * @param webResource
	 * @param tag
	 */
	public Redirect(Synonym oSyn, String sWebRes, String sTagname,
			boolean isPublic, short iState) {
		super(iState);
		this.oSynonym = oSyn;
		this.sWebResource = sWebRes;
		this.sTag = sTagname;
		this.bPublic = isPublic;
	}

	public String getWebResource() {
		return this.sWebResource;
	}

	public void setWebResource(String webResource) {
		this.sWebResource = webResource;
	}

	public Synonym getSynonym() {
		return this.oSynonym;
	}

	public void setSynonym(Synonym oSyn) {
		this.oSynonym = oSyn;
	}

	public String getTag() {
		return this.sTag;
	}

	public void setTag(String tag) {
		this.sTag = tag;
	}

	public boolean getPublic() {
		return this.bPublic;
	}

	public void setPublic(boolean isPublic) {
		this.bPublic = isPublic;
	}

	public void debug(String prefix) {
		oLogger.debug(prefix + " : Redirects (" + id + ", " + sWebResource
				+ ", " + sTag + " , " + oSynonym.getId() + ", " + state + ")");
	}
}